package com.dc.designPattern._23_specification.impl.step3.spec;

/**
 * Description: 规格模式_基类
 * @author: gdc
 * @date: 2021/8/20
 * @version 1.0
 */
public abstract class BaseUserSpecification implements IUserSpecification {

    @Override
    public IUserSpecification and(IUserSpecification spec) {
        return new AndSpecification(this, spec);
    }

    @Override
    public IUserSpecification or(IUserSpecification spec) {
        return new OrSpecification(this, spec);
    }

    @Override
    public IUserSpecification not() {
        return new NotSpecification(this);
    }
}
